1. Field of the Invention
The present invention relates to logs for server resources and, more particularly, to transaction logs for resources of Network File System (NFS) servers.
2. Description of the Related Art
Conventionally, logs have been produced for various different protocols. In recent years, logs for HTTP and FTP protocols have been developed to monitor access to files or web pages. One example is WU-FTPd provided by Washington University of St. Louis, Mo. which logs FTP server activity and produces a logfile. Networking tracing utilities have also been developed to analyze network traffic. Network tracing often involves examination of data packets as well as presentation of traffic or transaction information to network administrators. See, e.g., U.S. Pat. Nos. 5,787,253; 5,648,965; and 5,740,355.
NFS is a protocol for use with file servers. The NFS protocol is defined in protocol specifications RFC 1094 and RFC 1813, which are hereby incorporated by reference. NFS clients can perform file and directory operations on NFS server resources via Remote Procedure Calls (RPCs).
NFS operations performed through RPCs include uploading (writing) or downloading (reading) files from a NFS server. A NFS file is downloaded over a network from a NFS server by first performing a NFS lookup operation to locate the desired object (filehandle of the file or directory). A series of subsequent NFS read operations will normally follow to obtain the actual file data at given offsets in location. The RPC operations may arrive out of order, or the client may request only a subset of the data in the file. A NFS file is uploaded over the network to an NFS server by first performing an NFS lookup operation to locate the corresponding object (filehandle). A series of NFS write operations will typically follow, each of which provides the corresponding offset in the file where the information will be written, as well as the information itself.
Many file related operations have a one to one mapping to NFS protocol operations. For instance, a directory is created by using a single NFS mkdir operation, a file is removed by using a single NFS remove operation, a directory is removed by using a single NFS rmdir operation. However, other file related operations map to multiple NFS operations. For example, as noted above, a file can be download by issuing multiple NFS read operations and a file can be upload by issuing multiple NFS write operations. In either case, when multiple NFS operations are used to perform access operations, the NFS server has no idea of how many reads the download will generate (particularly since the NFS client may choose to generate reads at different offsets out of order) or no idea of how many writes the upload will generate (since the NFS client does not specify the size of the file before it starts writing to the file).
One problem with these conventional logging systems is that they are not suitable for use with the NFS protocol and thus not satisfactory for logging access to NFS servers. Since the NFS protocol does not use an open or close procedure and since the certain operations or transactions are often performed with multiple NFS operations, conventional logging systems do not have any way to know when certain NFS operations (e.g., read and write) have completed. Thus, there is a need for techniques for logging transactions to NFS servers.